package com.example.service;

import com.example.entity.User;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface UserService {
    User getUserById(int uid);
    List<User> getAllUser();
    boolean addUser(User user);
    boolean updateUser(User user);
    boolean deleteUser(Integer uid);
    User findByNameAndPassword(String username,String password);
    List<User> searchByUsername(String username);


    // 通过uid修改信息
    User findByUid( Integer uid);
    //更新用户积分
    int updateScore(@Param("uid") int uid, @Param("score") int score);
}
